		<!-- 动物检疫合格证明（动物A） -->
<template>
	<view style="width: 100%;">
		<uni-list>
			<uni-list>
				<uni-list-item title="合格证号(NO)" :note="datas.certificateNumber" :show-arrow="false"/>
				<uni-list-item title="系统编号" :note="datas.code" :show-arrow="false"/>
				<uni-list-item title="货主" :note="datas.shipperName" :show-arrow="false"/>
				<uni-list-item title="联系电话" :note="datas.shipperTel" :show-arrow="false"/>
				<uni-list-item title="动物种类" :note="datas.animalType" :show-arrow="false"/>
				<uni-list-item title="规格及数量" :note="datas.numUnit" :show-arrow="false"/>
			
				<uni-list-item title="起运地点" :note="datas.departureAddress" :show-arrow="false"/>
				<uni-list-item title="到达地点" :note="datas.arrivalAddress" :show-arrow="false"/>
					<uni-list-item title="用途" :note="datas.purpose" :show-arrow="false"/>
					<uni-list-item title="承运人" :note="datas.carrier" :show-arrow="false"/>
					<uni-list-item title="承运人联系电话" :note="datas.carrierTel" :show-arrow="false"/>
						<uni-list-item title="运载方式" :note="datas.deliveryWay" :show-arrow="false"/>
						<uni-list-item title="运载工具牌号" :note="datas.plateNumber" :show-arrow="false"/>
						<uni-list-item title="运载工具消毒情况" :note="'装运前经'+datas.sterilizeCondition+'消毒'" :show-arrow="false"/>
						<uni-list-item title="到达有效日" :note="datas.dayValid" :show-arrow="false"/>
				<uni-list-item title="水产苗种生产许可证号" :note="datas.productionLicenseNumber" :show-arrow="false"/>
				<uni-collapse accordion="true" >
					<uni-collapse-item title="牲畜耳标号" animation="true">
						<view style="margin-left: 30upx;" v-for="item in datas.animalEarLabel"><span>质量合格证号:{{item.qcNumber}}</span> <span style="padding-left: 10upx;">规格：{{item.spec}}</span> <span style="padding-left: 10upx;">数量:{{item.number}} </span></view>
					</uni-collapse-item>
				</uni-collapse>
				<uni-list-item title="备注" :note="datas.remarks" :show-arrow="false"/>
				<uni-list-item title="签发日期" :note="datas.issuanceTime|dateFormat" :show-arrow="false"/>
			</uni-list>
		</uni-list>
	</view>
</template>

<script>
import uniSection from '@/components/uni-section/uni-section.vue';
import uniList from '@/components/uni-list/uni-list.vue';
import uniListItem from '@/components/uni-list-item/uni-list-item.vue';
import uniCollapse from "@/components/uni-collapse/uni-collapse.vue"
	import uniCollapseItem from "@/components/uni-collapse-item/uni-collapse-item.vue";
	import loginjs from '@/login.js'
	import {
		mapState
	} from 'vuex'
export default {
	computed: mapState(['baseUrl']),
	components: {
		uniCollapse,
		uniCollapseItem,
		uniSection,
		uniList,
		uniListItem
	},
	data() {
		return {
			Authorization: null,
			datas: {
			
			}
		};
	},
	methods: {
		onLoad(option) {
			this.Authorization = loginjs.getAuthorization();
			console.log(option.id)
			this.getList(option.id)
		},
		getList(id) {
			uni.request({
				method: "GET",
				url: this.baseUrl + 'api/quarantine/certification/' + id,
				header: {
					"Authorization": this.Authorization,
				},
				success: (res) => {
					this.datas = res.data.data
					this.datas.animalEarLabel=JSON.parse(this.datas.animalEarLabel)
					if(this.datas.deliveryWay==1){
						this.datas.deliveryWay='公路'
					}else if(this.datas.deliveryWay==2){
						this.datas.deliveryWay='铁路'
					}else if(this.datas.deliveryWay==3){
						this.datas.deliveryWay='水路'
					}else{
						this.datas.deliveryWay='航空'
					}
				}
			})
		}
	}
};
</script>

<style>

</style>
